﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Freejobber.Core.Generic.Helpers;
using Freejobber.Core.Generic.Security;

namespace Freejobber.Master
{
    public partial class Site : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            Response.AppendHeader("Connection", "keep-alive");
            try
            {
               // MailHelperClass.SendRegisterEmail("gelleor@gmail.com", "uhuh");
                if (Request["SignOut"].ToString() == "1")
                {
                    SecurityManager.SignOut();
                    Response.Redirect("~/default.aspx");
                    Response.End();
                }
            }
            catch(Exception ex)
            { }
            //string city= IpGeoLocation.GetLocationByIp(Request.UserHostAddress);
          /*  System.Web.Caching.Cache citycach = new System.Web.Caching.Cache();
            citycach.Add("mycity", 0, null, new DateTime(DateTime.Now.AddDays(1)), null, System.Web.Caching.CacheItemPriority.Default, null);
            if(citycach["mycity"]==null)
                citycach["mycity"] = IpGeoLocation.GetLocationByIp("109.173.101.110");
            divUserCity.InnerText = citycach["mycity"].ToString();*/
        }
    }
}